\doxysection{C\+:/\+Users/\+ASUS/\+Desktop/dm-\/ctrl\+H7-\/balance-\/9025test/\+Drivers/\+STM32\+H7xx\+\_\+\+HAL\+\_\+\+Driver/\+Inc/stm32h7xx\+\_\+hal\+\_\+gpio.h File Reference}
\hypertarget{stm32h7xx__hal__gpio_8h}{}\label{stm32h7xx__hal__gpio_8h}\index{C:/Users/ASUS/Desktop/dm-\/ctrlH7-\/balance-\/9025test/Drivers/STM32H7xx\_HAL\_Driver/Inc/stm32h7xx\_hal\_gpio.h@{C:/Users/ASUS/Desktop/dm-\/ctrlH7-\/balance-\/9025test/Drivers/STM32H7xx\_HAL\_Driver/Inc/stm32h7xx\_hal\_gpio.h}}


Header file of GPIO HAL module.  


{\ttfamily \#include "{}stm32h7xx\+\_\+hal\+\_\+def.\+h"{}}\newline
{\ttfamily \#include "{}stm32h7xx\+\_\+hal\+\_\+gpio\+\_\+ex.\+h"{}}\newline
\doxysubsubsection*{Classes}
\begin{DoxyCompactItemize}
\item 
struct \mbox{\hyperlink{struct_g_p_i_o___init_type_def}{GPIO\+\_\+\+Init\+Type\+Def}}
\begin{DoxyCompactList}\small\item\em GPIO Init structure definition. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsubsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+0}~((uint16\+\_\+t)0x0001)  /\texorpdfstring{$\ast$}{*} Pin 0 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+1}~((uint16\+\_\+t)0x0002)  /\texorpdfstring{$\ast$}{*} Pin 1 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+2}~((uint16\+\_\+t)0x0004)  /\texorpdfstring{$\ast$}{*} Pin 2 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+3}~((uint16\+\_\+t)0x0008)  /\texorpdfstring{$\ast$}{*} Pin 3 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+4}~((uint16\+\_\+t)0x0010)  /\texorpdfstring{$\ast$}{*} Pin 4 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+5}~((uint16\+\_\+t)0x0020)  /\texorpdfstring{$\ast$}{*} Pin 5 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+6}~((uint16\+\_\+t)0x0040)  /\texorpdfstring{$\ast$}{*} Pin 6 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+7}~((uint16\+\_\+t)0x0080)  /\texorpdfstring{$\ast$}{*} Pin 7 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+8}~((uint16\+\_\+t)0x0100)  /\texorpdfstring{$\ast$}{*} Pin 8 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+9}~((uint16\+\_\+t)0x0200)  /\texorpdfstring{$\ast$}{*} Pin 9 selected    \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+10}~((uint16\+\_\+t)0x0400)  /\texorpdfstring{$\ast$}{*} Pin 10 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+11}~((uint16\+\_\+t)0x0800)  /\texorpdfstring{$\ast$}{*} Pin 11 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+12}~((uint16\+\_\+t)0x1000)  /\texorpdfstring{$\ast$}{*} Pin 12 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+13}~((uint16\+\_\+t)0x2000)  /\texorpdfstring{$\ast$}{*} Pin 13 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+14}~((uint16\+\_\+t)0x4000)  /\texorpdfstring{$\ast$}{*} Pin 14 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+15}~((uint16\+\_\+t)0x8000)  /\texorpdfstring{$\ast$}{*} Pin 15 selected   \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+\+All}~((uint16\+\_\+t)0x\+FFFF)  /\texorpdfstring{$\ast$}{*} All pins selected \texorpdfstring{$\ast$}{*}/
\item 
\#define {\bfseries GPIO\+\_\+\+PIN\+\_\+\+MASK}~(0x0000\+FFFFU) /\texorpdfstring{$\ast$}{*} PIN mask for assert test \texorpdfstring{$\ast$}{*}/
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_gaf40bec3146810028a84b628d37d3b391}{GPIO\+\_\+\+MODE\+\_\+\+INPUT}}~MODE\+\_\+\+INPUT
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga1013838a64cec2f8c88f079c449d1982}{GPIO\+\_\+\+MODE\+\_\+\+OUTPUT\+\_\+\+PP}}~(MODE\+\_\+\+OUTPUT \texorpdfstring{$\vert$}{|} OUTPUT\+\_\+\+PP)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga2f91757829f6e9505ec386b840941929}{GPIO\+\_\+\+MODE\+\_\+\+OUTPUT\+\_\+\+OD}}~(MODE\+\_\+\+OUTPUT \texorpdfstring{$\vert$}{|} OUTPUT\+\_\+\+OD)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga526c72c5264316fc05c775b6cad4aa6a}{GPIO\+\_\+\+MODE\+\_\+\+AF\+\_\+\+PP}}~(MODE\+\_\+\+AF \texorpdfstring{$\vert$}{|} OUTPUT\+\_\+\+PP)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga282b9fd37c8ef31daba314ffae6bf023}{GPIO\+\_\+\+MODE\+\_\+\+AF\+\_\+\+OD}}~(MODE\+\_\+\+AF \texorpdfstring{$\vert$}{|} OUTPUT\+\_\+\+OD)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga7a04f9ab65ad572ad20791a35009220c}{GPIO\+\_\+\+MODE\+\_\+\+ANALOG}}~MODE\+\_\+\+ANALOG
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga088659562e68426d9a72821ea4fd8d50}{GPIO\+\_\+\+MODE\+\_\+\+IT\+\_\+\+RISING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+IT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+RISING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_gaa166210a6da3ac7e8d7504702520e522}{GPIO\+\_\+\+MODE\+\_\+\+IT\+\_\+\+FALLING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+IT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+FALLING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga0678e61090ed61e91a6496f22ddfb3d1}{GPIO\+\_\+\+MODE\+\_\+\+IT\+\_\+\+RISING\+\_\+\+FALLING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+IT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+RISING \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+FALLING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga97d78b82ea178ff7a4c35aa60b4e9338}{GPIO\+\_\+\+MODE\+\_\+\+EVT\+\_\+\+RISING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+EVT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+RISING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_gadbfa532b3566783ac6c0e07c2e0ffe5e}{GPIO\+\_\+\+MODE\+\_\+\+EVT\+\_\+\+FALLING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+EVT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+FALLING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__mode__define_ga1b760771297ed2fc55a6b13071188491}{GPIO\+\_\+\+MODE\+\_\+\+EVT\+\_\+\+RISING\+\_\+\+FALLING}}~(MODE\+\_\+\+INPUT \texorpdfstring{$\vert$}{|} EXTI\+\_\+\+EVT \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+RISING \texorpdfstring{$\vert$}{|} TRIGGER\+\_\+\+FALLING)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__speed__define_gab7916c4265bfa1b26a5205ea9c1caa4e}{GPIO\+\_\+\+SPEED\+\_\+\+FREQ\+\_\+\+LOW}}~(0x00000000U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__speed__define_ga1724a25a9cf00ebf485daeb09cfa1e25}{GPIO\+\_\+\+SPEED\+\_\+\+FREQ\+\_\+\+MEDIUM}}~(0x00000001U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__speed__define_gaef5898db71cdb957cd41f940b0087af8}{GPIO\+\_\+\+SPEED\+\_\+\+FREQ\+\_\+\+HIGH}}~(0x00000002U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__speed__define_ga1944cf10e2ab172810d38b681d40b771}{GPIO\+\_\+\+SPEED\+\_\+\+FREQ\+\_\+\+VERY\+\_\+\+HIGH}}~(0x00000003U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__pull__define_ga5c2862579882c1cc64e36d38fbd07a4c}{GPIO\+\_\+\+NOPULL}}~(0x00000000U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__pull__define_gae689bc8f5c42d6df7bd54a8dd372e072}{GPIO\+\_\+\+PULLUP}}~(0x00000001U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o__pull__define_ga75d958d0410c36da7f27d1f4f5c36c14}{GPIO\+\_\+\+PULLDOWN}}~(0x00000002U)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___exported___macros_gaae18fc8d92ffa4df2172c78869e712fc}{\+\_\+\+\_\+\+HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+GET\+\_\+\+FLAG}}(\+\_\+\+\_\+\+EXTI\+\_\+\+LINE\+\_\+\+\_\+)
\begin{DoxyCompactList}\small\item\em Checks whether the specified EXTI line flag is set or not. \end{DoxyCompactList}\item 
\#define \mbox{\hyperlink{group___g_p_i_o___exported___macros_ga2f28fc349d1812cdc55a77c68d2b278d}{\+\_\+\+\_\+\+HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+CLEAR\+\_\+\+FLAG}}(\+\_\+\+\_\+\+EXTI\+\_\+\+LINE\+\_\+\+\_\+)
\begin{DoxyCompactList}\small\item\em Clears the EXTI\textquotesingle{}s line pending flags. \end{DoxyCompactList}\item 
\#define \mbox{\hyperlink{group___g_p_i_o___exported___macros_ga27f0e1f6c38745169d74620f6a178a94}{\+\_\+\+\_\+\+HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+GET\+\_\+\+IT}}(\+\_\+\+\_\+\+EXTI\+\_\+\+LINE\+\_\+\+\_\+)
\begin{DoxyCompactList}\small\item\em Checks whether the specified EXTI line is asserted or not. \end{DoxyCompactList}\item 
\#define \mbox{\hyperlink{group___g_p_i_o___exported___macros_ga2a086506eec826f49b200fba64beb9f1}{\+\_\+\+\_\+\+HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+CLEAR\+\_\+\+IT}}(\+\_\+\+\_\+\+EXTI\+\_\+\+LINE\+\_\+\+\_\+)
\begin{DoxyCompactList}\small\item\em Clears the EXTI\textquotesingle{}s line pending bits. \end{DoxyCompactList}\item 
\#define \mbox{\hyperlink{group___g_p_i_o___exported___macros_gac50aef6881e1f76032941ead9c9bce61}{\+\_\+\+\_\+\+HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+GENERATE\+\_\+\+SWIT}}(\+\_\+\+\_\+\+EXTI\+\_\+\+LINE\+\_\+\+\_\+)
\begin{DoxyCompactList}\small\item\em Generates a Software interrupt on selected EXTI line. \end{DoxyCompactList}\item 
\#define {\bfseries GPIO\+\_\+\+MODE\+\_\+\+Pos}~0u
\item 
\#define {\bfseries GPIO\+\_\+\+MODE}~(0x3uL $<$$<$ GPIO\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries MODE\+\_\+\+INPUT}~(0x0uL $<$$<$ GPIO\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries MODE\+\_\+\+OUTPUT}~(0x1uL $<$$<$ GPIO\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries MODE\+\_\+\+AF}~(0x2uL $<$$<$ GPIO\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries MODE\+\_\+\+ANALOG}~(0x3uL $<$$<$ GPIO\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries OUTPUT\+\_\+\+TYPE\+\_\+\+Pos}~4u
\item 
\#define {\bfseries OUTPUT\+\_\+\+TYPE}~(0x1uL $<$$<$ OUTPUT\+\_\+\+TYPE\+\_\+\+Pos)
\item 
\#define {\bfseries OUTPUT\+\_\+\+PP}~(0x0uL $<$$<$ OUTPUT\+\_\+\+TYPE\+\_\+\+Pos)
\item 
\#define {\bfseries OUTPUT\+\_\+\+OD}~(0x1uL $<$$<$ OUTPUT\+\_\+\+TYPE\+\_\+\+Pos)
\item 
\#define {\bfseries EXTI\+\_\+\+MODE\+\_\+\+Pos}~16u
\item 
\#define {\bfseries EXTI\+\_\+\+MODE}~(0x3uL $<$$<$ EXTI\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries EXTI\+\_\+\+IT}~(0x1uL $<$$<$ EXTI\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries EXTI\+\_\+\+EVT}~(0x2uL $<$$<$ EXTI\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries TRIGGER\+\_\+\+MODE\+\_\+\+Pos}~20u
\item 
\#define {\bfseries TRIGGER\+\_\+\+MODE}~(0x7uL $<$$<$ TRIGGER\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries TRIGGER\+\_\+\+RISING}~(0x1uL $<$$<$ TRIGGER\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries TRIGGER\+\_\+\+FALLING}~(0x2uL $<$$<$ TRIGGER\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define {\bfseries TRIGGER\+\_\+\+LEVEL}~(0x4uL $<$$<$ TRIGGER\+\_\+\+MODE\+\_\+\+Pos)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___private___macros_ga6da646a4924c5cfae3024c660476f26f}{IS\+\_\+\+GPIO\+\_\+\+PIN\+\_\+\+ACTION}}(ACTION)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___private___macros_ga4911823233fa2bf64a4f04c6dbfa5485}{IS\+\_\+\+GPIO\+\_\+\+PIN}}(\+\_\+\+\_\+\+PIN\+\_\+\+\_\+)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___private___macros_gacc5fde3eef57ec3c558c11d0011d900c}{IS\+\_\+\+GPIO\+\_\+\+MODE}}(MODE)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___private___macros_ga888e1f951df2fe9dbf827528051a3a56}{IS\+\_\+\+GPIO\+\_\+\+SPEED}}(SPEED)
\item 
\#define \mbox{\hyperlink{group___g_p_i_o___private___macros_ga1cb9706d23fb79584aae41e5e503f3cd}{IS\+\_\+\+GPIO\+\_\+\+PULL}}(PULL)
\end{DoxyCompactItemize}
\doxysubsubsection*{Enumerations}
\begin{DoxyCompactItemize}
\item 
\Hypertarget{group___g_p_i_o___exported___types_ga5b3ef0486b179415581eb342e0ea6b43}\label{group___g_p_i_o___exported___types_ga5b3ef0486b179415581eb342e0ea6b43} 
enum \mbox{\hyperlink{group___g_p_i_o___exported___types_ga5b3ef0486b179415581eb342e0ea6b43}{GPIO\+\_\+\+Pin\+State}} \{ {\bfseries GPIO\+\_\+\+PIN\+\_\+\+RESET} = 0U
, {\bfseries GPIO\+\_\+\+PIN\+\_\+\+SET}
 \}
\begin{DoxyCompactList}\small\item\em GPIO Bit SET and Bit RESET enumeration. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void {\bfseries HAL\+\_\+\+GPIO\+\_\+\+Init} (\mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, const \mbox{\hyperlink{struct_g_p_i_o___init_type_def}{GPIO\+\_\+\+Init\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIO\+\_\+\+Init)
\item 
void {\bfseries HAL\+\_\+\+GPIO\+\_\+\+De\+Init} (\mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, uint32\+\_\+t GPIO\+\_\+\+Pin)
\item 
\mbox{\hyperlink{group___g_p_i_o___exported___types_ga5b3ef0486b179415581eb342e0ea6b43}{GPIO\+\_\+\+Pin\+State}} {\bfseries HAL\+\_\+\+GPIO\+\_\+\+Read\+Pin} (const \mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, uint16\+\_\+t GPIO\+\_\+\+Pin)
\item 
void {\bfseries HAL\+\_\+\+GPIO\+\_\+\+Write\+Pin} (\mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, uint16\+\_\+t GPIO\+\_\+\+Pin, \mbox{\hyperlink{group___g_p_i_o___exported___types_ga5b3ef0486b179415581eb342e0ea6b43}{GPIO\+\_\+\+Pin\+State}} Pin\+State)
\item 
void {\bfseries HAL\+\_\+\+GPIO\+\_\+\+Toggle\+Pin} (\mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, uint16\+\_\+t GPIO\+\_\+\+Pin)
\item 
\mbox{\hyperlink{stm32h7xx__hal__def_8h_a63c0679d1cb8b8c684fbb0632743478f}{HAL\+\_\+\+Status\+Type\+Def}} {\bfseries HAL\+\_\+\+GPIO\+\_\+\+Lock\+Pin} (\mbox{\hyperlink{struct_g_p_i_o___type_def}{GPIO\+\_\+\+Type\+Def}} \texorpdfstring{$\ast$}{*}GPIOx, uint16\+\_\+t GPIO\+\_\+\+Pin)
\item 
void {\bfseries HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+IRQHandler} (uint16\+\_\+t GPIO\+\_\+\+Pin)
\item 
void \mbox{\hyperlink{group___g_p_i_o___exported___functions___group2_ga0cd91fd3a9608559c2a87a8ba6cba55f}{HAL\+\_\+\+GPIO\+\_\+\+EXTI\+\_\+\+Callback}} (uint16\+\_\+t GPIO\+\_\+\+Pin)
\begin{DoxyCompactList}\small\item\em EXTI中断回调函数,根据\+GPIO\+\_\+\+Pin找到对应的\+GPIOInstance,并调用模块回调函数(如果有) \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Header file of GPIO HAL module. 

\begin{DoxyAuthor}{Author}
MCD Application Team 
\end{DoxyAuthor}
\begin{DoxyAttention}{Attention}

\end{DoxyAttention}
Copyright (c) 2017 STMicroelectronics. All rights reserved.

This software is licensed under terms that can be found in the LICENSE file in the root directory of this software component. If no LICENSE file comes with this software, it is provided AS-\/\+IS. 